<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>willow</title>
    <link rel="stylesheet" type="text/css" href="test.css" />
</head>
<body>
    <h1>Hello World!</h1>
    <button>Change color</button>

    <script>
        var btn = document.querySelector('button');

        function random(number) {
        return Math.floor(Math.random()*(number+1));
        }

        btn.onclick = function() {
        var rndCol = 'rgb(' + random(255) + ',' + random(255) + ',' + random(255) + ')';
        document.body.style.backgroundColor = rndCol;
        }
    </script>
</body>
</html>